package com.inplaceedit.client.ui.contact;

import java.util.List;

import com.google.gwt.editor.client.Editor;
import com.google.gwt.editor.client.LeafValueEditor;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.inplaceedit.shared.dto.CompanyDto;
import com.inplaceedit.shared.dto.ContactDto;

public interface ContactNameEditor extends Editor<ContactDto> {
	public static interface Handler {
		void getCompanyList(AsyncCallback<List<CompanyDto>> callback);
	}

	@Editor.Path("company")
	LeafValueEditor<CompanyDto> getCompanySelector();

	@Editor.Path("firstName")
	LeafValueEditor<String> getFirstNameEditor();

	@Editor.Path("lastName")
	LeafValueEditor<String> getLastNameEditor();

	@Editor.Path("title")
	LeafValueEditor<String> getTitleEditor();

	@Editor.Ignore
	void refresh();

	@Editor.Ignore
	void setHandler(Handler handler);
}
